Skip to content

Conversation

NalinDalal
Copy link
Contributor

@NalinDalal NalinDalal commented Sep 23, 2025

This PR addresses issue #869 : ensuring that all <ul> and <ol> elements only have <li>, <script>, or <template> as direct children, as required by the HTML specification and accessibility guidelines.

What was changed

  • Refactored markup in three locations where <ul> or <ol> had non-<li> direct children.
  • All content/components that were direct children of <ul> are now wrapped in <li> elements.
  • Verified all other relevant files for similar issues; no further inconsistencies found.

Why

  • To comply with the HTML spec and improve accessibility (WCAG 1.3.1, H48, F43).
  • Prevents inconsistent rendering and improves support for assistive technologies.

How to test

  • Review affected pages in the browser and inspect the DOM to ensure all <ul> and <ol> have only <li>, <script>, or <template> as direct children.
  • Confirm that the UI and accessibility are not negatively impacted.

Related Issue

Closes #869

Additional Notes

  • If any similar issues are found elsewhere, please report or address them in follow-up PRs.

@NalinDalal NalinDalal changed the title updated the code with correct conventions in the required places Fix <ul> and <ol> Direct Children for HTML Compliance Sep 23, 2025
@coseeian
Copy link
Collaborator

I have reviewed this PR, and it looks good!

@ksen0 ksen0 merged commit 874d129 into processing:2.0 Oct 2, 2025
4 checks passed
@ksen0
Copy link
Member

ksen0 commented Oct 2, 2025

Hi @NalinDalal , since this is a global issue affecting also the main branch, please feel free to open a PR against main that cherrypicks this commit there. Thanks!

NalinDalal pushed a commit to NalinDalal/p5.js-website that referenced this pull request Oct 2, 2025
Fix `<ul>` and `<ol>` Direct Children for HTML Compliance
@NalinDalal
Copy link
Contributor Author

NalinDalal commented Oct 2, 2025

I attempted to cherry-pick commit 874d129 into main, but the changes for the <ul>/<ol> HTML compliance fix are already present there.

PR filed

ksen0 added a commit that referenced this pull request Oct 3, 2025
Fix `<ul>` and `<ol>` Direct Children for HTML Compliance
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants